package org.infodavid.common.model;

import java.util.Locale;
import java.util.Map;

import org.infodavid.common.model.behaviors.ICategorizable;
import org.infodavid.common.persistence.ICommented;
import org.infodavid.common.persistence.IDataObject;

/**
 * The Interface ITemplateVersion.
 */
public interface ITemplateVersion extends IDataObject<Long>, IVersionObject,
    ICategorizable<ITemplateCategory>, ICommented, IContentInfo {

  /** The DEFAULT_ENCODING. */
  String DEFAULT_ENCODING = "UTF-8";

  /** The IMAGES. */
  String IMAGES = "images";

  /** The DATA. */
  String DATA = "data";

  /** The ENCODING. */
  String ENCODING = "encoding";

  /** The LANGUAGE. */
  String LANGUAGE = "language";

  /** The constant MAX_LENGTH_ENCODING. */
  int MAX_LENGTH_ENCODING = 32;

  /** The ID. */
  String ID = "templateVersionKey";

  /** The constant MAX_LENGTH_SUBJECT. */
  int MAX_LENGTH_SUBJECT = 256;

  /** The SUBJECT. */
  String SUBJECT = "subject";

  /** The TEMPLATE_VERSION. */
  String TEMPLATE_VERSION = "templateVersion";

  /**
   * Gets the images.
   * @return the images
   */
  Map<String,IImageData> getImages();

  /**
   * Gets the data.
   * @return the data
   */
  byte[] getData();

  /**
   * Sets the data.
   * @param values the new data
   */
  void setData(byte[] values);

  /**
   * Gets the template.
   * @return the template
   */
  ITemplate getTemplate();

  /**
   * Sets the template.
   * @param value the new template
   */
  void setTemplate(ITemplate value);

  /**
   * Adds the image.
   * @param value the value
   */
  void addImage(IImageData value);

  /**
   * Removes the image.
   * @param value the value
   */
  void removeImage(IImageData value);

  /**
   * Gets the encoding.
   * @return the encoding
   */
  String getEncoding();

  /**
   * Gets the language.
   * @return the language
   */
  @Override
  Locale getLanguage();

  /**
   * Sets the encoding.
   * @param value the new encoding
   */
  void setEncoding(String value);

  /**
   * Sets the language.
   * @param value the new language
   */
  @Override
  void setLanguage(Locale value);

  /**
   * Gets the subject.
   * @return the subject
   */
  String getSubject();

  /**
   * Gets the user creator.
   * @return the user creator
   */
  IUser getUser();

  /**
   * Sets the subject.
   * @param value the new subject
   */
  void setSubject(String value);

  /**
   * Sets the user.
   * @param value the new user
   */
  void setUser(IUser value);
}
